package com.chinasoft04.mall.dto;

import com.chinasoft04.mall.pojo.AuthRolePojo;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.List;

@Data
@NoArgsConstructor
@AllArgsConstructor
public class AuthRoleDto {
    Integer id;
    String roleName;
    String roleDesc;
    Integer roleId;
    List<AuthRoleDtoChildrenPermission> children;

    public AuthRoleDto(AuthRolePojo rolePojo){
        this.id = rolePojo.getRole_id();
        this.roleId = rolePojo.getRole_id();
        this.roleName = rolePojo.getRole_name();
        this.roleDesc = rolePojo.getRole_desc();
    }
}
